package com.knight.hadoop.day04.bigdata.proxy;

import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;

public class MyHandler implements InvocationHandler{

	@Override
	public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
		Class<?> object= Class.forName("com.knight.bigdata.proxy.Boos");
		System.out.println("MyHandler invoke method: "+method.getName());
		System.out.println("MyHandler invoke args: "+args);
		return method.invoke(object.newInstance(), args);
	}

}
